<?php 

class Order_Form_SearchOrder extends Custom_Form_Abstract{
	
	public function init(){
		
		$this->addElement('text', 'orderId', array(
            'decorators'	=>	$this->elementDecorators,
        	'label'		=>	'Order Id',
        	'required'   => false,
        ));
        
        $this->addElement('select', 'status', array(
            'decorators' => $this->elementDecorators,
            'label'       => 'Order Status',
        	'multiOptions'	=> Doctrine_Core::getTable('Doctrine_Model_Orders')->getEnumValues('status')
        ));
        
        $this->addElement('text', 'startDate', array(
        	'decorators' => $this->elementDecorators,
	        'required'   => false,
	        'validators'  => array (
	            array('date', false, array('MM/dd/yyyy'))
	        ),
	        'label'      => 'Start Date'
	    ));
	    
        $this->addElement('text', 'endDate', array(
        	'decorators' => $this->elementDecorators,
	        'required'   => false,
	        'validators'  => array (
	            array('date', false, array('MM/dd/yyyy'))
	        ),
	        'label'      => 'End Date'
	    ));
        
        $this->addElement('submit', 'searchOrder', array(
        	'decorators' => $this->buttonDecorators,
        ));
	}
}